package com.tintintech.sendmail.protocol;

import java.text.SimpleDateFormat;
import java.util.Date;
import java.util.Locale;

public abstract class Message {
	
	protected String fromname;
	protected String fromemail;
	protected String toname;
	protected String toemail;
	protected String subject;
	protected String content;
	
	protected boolean html = false;
	protected boolean notification = false;
	
	protected static String CRLF = "\r\n";
	
	public String getFromName()
	{
		return this.fromname;
	}
	
	public String getFromEmail()
	{
		return this.fromemail;
	}
	
	public String getToName()
	{
		return this.toname;
	}
	
	public String getToEmail()
	{
		return this.toemail;
	}
	
	public String getSubject()
	{
		return this.subject;
	}
	
	public String getContent()
	{
		return this.content;
	}
	
	public boolean getHtml()
	{
		return this.html;
	}
	
	public boolean getNotification()
	{
		return this.notification;
	}
	
	public String getSendDate()
	{
		return new SimpleDateFormat("EEE, d MMM yyyy HH:mm:ss Z", Locale.ENGLISH).format(new Date());
	}
	
	public abstract String getMessageBody();
}
